<!--{if $_G['setting']['mobile']['mobilehotthread'] && $_GET['forumlist'] != 1}-->
	<!--{eval dheader('Location:portal.php?mod=index&mobile=2');exit;}-->
<!--{/if}-->
<!--{template common/header}-->

<script type="text/javascript">
	function getvisitclienthref() {
		var visitclienthref = '';
		if(ios) {
			visitclienthref = 'https://itunes.apple.com/cn/app/zhang-shang-lun-tan/id489399408?mt=8';
		} else if(andriod) {
			visitclienthref = 'http://www.discuz.net/mobile.php?platform=android';
		}
		return visitclienthref;
	}
</script>

<!--{if $_GET['visitclient']}-->

<header class="header">
    <div class="nav">
		<span>{lang warmtip}</span>
    </div>
</header>
<div class="cl">
	<div class="clew_con">
		<h2 class="tit">{lang zsltmobileclient}</h2>
		<p>{lang visitbbsanytime}<input class="redirect button" id="visitclientid" type="button" value="{lang clicktodownload}" href="" /></p>
		<h2 class="tit">{lang iphoneandriodmobile}</h2>
		<p>{lang visitwapmobile}<input class="redirect button" type="button" value="{lang clicktovisitwapmobile}" href="$_GET[visitclient]" /></p>
	</div>
</div>
<script type="text/javascript">
	var visitclienthref = getvisitclienthref();
	if(visitclienthref) {
		$('#visitclientid').attr('href', visitclienthref);
	} else {
		window.location.href = '$_GET[visitclient]';
	}
</script>

<!--{else}-->

<!-- header start -->
<!--{if $showvisitclient}-->

<div class="visitclienttip vm" style="display:block;">
	<a href="javascript:;" id="visitclientid" class="btn_download">{lang downloadnow}</a>	
	<p>
		{lang downloadzslttoshareview}
	</p>
</div>
<script type="text/javascript">
	var visitclienthref = getvisitclienthref();
	if(visitclienthref) {
		$('#visitclientid').attr('href', visitclienthref);
		$('.visitclienttip').css('display', 'block');
	}
</script>

<!--{/if}-->

<!-- header start -->
<div class="bz-header">
	<div class="bz-header-left bzleft">
		<a class="iconfont icon-guanzhu"></a>
	</div>
	<h2>$_G['setting']['bbname']</h2>
	<div class="bz-header-right">
		<a href="<!--{if $_GET['mod'] == 'forumdisplay' || $_GET['mod'] == 'viewthread'}-->forum.php?mod=post&action=newthread&fid=$_G['fid']<!--{else}-->forum.php?mod=misc&action=nav<!--{/if}-->" class="iconfont icon-fatie"></a>
	</div>
</div>
<!--{template common/bzlnav}-->
<div class="banzhuan-top"></div>
<!-- header end -->

<!--{hook/index_top_mobile}-->
<!-- main forumlist start -->
<div class="banzhuan-h10"></div>
<!--{if empty($gid)}-->
		<div id="chart" class="cl bz-bg-fff bz-p10">
			<ul>
				<li>
					<span>{lang index_today}</span>
					<em>$todayposts</em>
				</li>
				<li>
					<span>{lang index_posts}</span>
					<em>$posts</em>
				</li>
				<li>
					<span>{lang index_members}</span>
					<em>$_G['cache']['userstats']['totalmembers']</em>
				</li>
			</ul>
		</div>
<!--{/if}-->

<div class="bz-mtb10" id="wp">
	
	<!--{loop $catlist $key $cat}-->
	<div class="bz-mb10">
		<div class="subforumshow bm_h cl banzhuan-clear" href="#sub_forum_$cat[fid]">
			<span class="o">
				<em class="iconfont <!--{if !$_G[setting][mobile][mobileforumview]}-->icon-kaiguan-kai color-f60 <!--{else}--> icon-kaiguan-guan color-b<!--{/if}-->"></em>
			</span>
		    <h2><a href="javascript:;">$cat[name]</a></h2>
		</div>
		<div id="sub_forum_$cat[fid]" class="sub_forum">
			<ul>
				<!--{loop $cat[forums] $forumid}-->
				<!--{eval $forum=$forumlist[$forumid];}-->
				<!--{eval $forumurl = !empty($forum['domain']) && !empty($_G['setting']['domain']['root']['forum']) ? 'http://'.$forum['domain'].'.'.$_G['setting']['domain']['root']['forum'] : 'forum.php?mod=forumdisplay&fid='.$forum['fid'];}-->
				<li>
					<div>
	                    <!--{if $forum[icon]}-->
	                        {$forum[icon]}
	                    <!--{else}-->
	                        <a href="forum.php?mod=forumdisplay&fid={$forum['fid']}&filter=lastpost&orderby=lastpost&mobile=2">
	                            <span class="nopic"></span>
	                        </a>
	                    <!--{/if}-->
	                    <!--{if $forum[todayposts] > 0}-->
						    <span class="num">$forum[todayposts]</span>
						<!--{/if}-->
				    </div>
                    	<div class="name">{$forum[name]}</div>
				</li>
				<!--{/loop}-->
			</ul>
		</div>
	</div>
	<!--{/loop}-->
	
</div>
<!-- main forumlist end -->

<!--{hook/index_middle_mobile}-->
<script type="text/javascript">
	(function() {
		<!--{if !$_G[setting][mobile][mobileforumview]}-->
			$('.sub_forum').css('display', 'block');
		<!--{else}-->
			$('.sub_forum').css('display', 'none');
		<!--{/if}-->
		$('.subforumshow').on('click', function() {
			var obj = $(this);
			var subobj = $(obj.attr('href'));
			if(subobj.css('display') == 'none') {
				subobj.css('display', 'block');
				obj.find('em').attr('class', 'iconfont icon-kaiguan-kai color-f60');
			} else {
				subobj.css('display', 'none');
				obj.find('em').attr('class', 'iconfont icon-kaiguan-guan color-b');
			}
		});
	 })();
</script>
<!--{/if}-->

<!--{template common/footer}-->